'use strict';
/**
 * @author [chenmin]
 * @class 弹出框－－－－话术
 */

var React = require('react');
var Router = require('react-router'); 

var PanelRouterAction = require('../../actions/panelRouter');


var ModalUtilMsgComponent = React.createClass({
  getInitialState:function(){
  	return { isOpen:"do-open-panel"}
  },
  componentWillReceiveProps:function(){
  	this.props.isActive?this.setState({isOpen:'do-open-panel do-open-panel-active'}):this.setState({isOpen:'do-open-panel'});	
  },
  handlerClose:function(){
  	this.setState({isOpen:"do-open-panel"});
  },
  handlerWordsPanel:function(){
  	PanelRouterAction.PANEL_ROUTER_WORDS({});
  },
  render: function() {
    return (
	/* jshint ignore:start */
		        <div className={this.state.isOpen} >
		                  <div className="do-open-panel-head">
		                        <a className="do-head-title" href="javascript:;" onClick={this.handlerClose} > <i className="fa fa-times"></i>
		                              关闭
		                        </a>
		                        <a className="do-head-title" href="javascript:;" onClick={this.handlerWordsPanel} > <i className="fa fa-cog"></i>
		                              设置
		                        </a>
		                  </div>
		                  <div className="do-open-panel-body">
		                        <ul className="do-nav-list-tabs">
		                              <li >
		                                    <a href="javascript:;">话术一</a>
		                              </li>
		                              <li>
		                                    <a href="javascript:;">话术二</a>
		                              </li>
		                              <li>
		                                    <a href="javascript:;">话术三</a>
		                              </li>
		                        </ul>
		                        <ul className="do-nav-list-slide">
		                              <li>
		                                    <a href="javascript:;"><i className="fa fa-caret-left"></i></a>
		                              </li>
		                              <li>
		                                    <a href="javascript:;"><i className="fa fa-caret-right"></i></a>
		                              </li>
		                        </ul>
		                        <div className="do-open-panel-content">
		                              <a href="javascript:;javascript:;">您没有添加过话术</a>
		                        </div>
		                  	{/*<span className="arrow"></span>*/}
		                  </div>
		            </div>
	/* jshint ignore:end */
    );
  }
});

module.exports =ModalUtilMsgComponent;